﻿@if (Request.IsAuthenticated)
{
  using (Html.BeginForm("Logout", "Authentication", FormMethod.Post, new { id = "logoutForm", @class = "navbar-right" }))
  {
    @Html.AntiForgeryToken()

    <ul class="nav navbar-nav navbar-right">
      <li>
        <div style="padding-top: 15px;padding-bottom: 15px;color:#9d9d9d;">
          @String.Format("Bonjour {0}!", User.Identity.Name)
        </div>
      </li>
      <li><a href="javascript:document.getElementById('logoutForm').submit()">Déconnexion</a></li>
    </ul>
  }
}
else
{
  <ul class="nav navbar-nav navbar-right">
    <li>@Html.ActionLink("Connexion", "Login", "Authentication", routeValues: null, htmlAttributes: new { id = "loginLink" })</li>
  </ul>
}
